/**
 * 
 */
package org.softTank.BC.data;

import org.softTank.BC.entity.services.Operation;
import org.springside.modules.test.DataUtils;

/**
 * @author Yuzone
 *
 */
public class OperationData {

	public static Operation getRandomOperationWithoutFK() {
		Operation o = new Operation();
		o.setName(DataUtils.randomName("operation"));
		o.setDescription("desc");
		o.setLocation("location");
		o.setNamespace("ns");

		return o;
	}

	public static Operation getRandomOperationWithFK() {
		Operation o = getRandomOperationWithoutFK();
		o.setId(1L);
		o.setPortType(PortTypeData.getTestPortType());
		o.setInput(MessageTypeData.getTestMessageType());

		return o;
	}

	public static Operation getTestOperation() {
		Operation o = getRandomOperationWithoutFK();
		o.setId(1L);

		return o;
	}

	public static Operation getOperationWithInferiors() {
		Operation o = getRandomOperationWithoutFK();
		o.setId(1L);
		o.setInput(MessageTypeData.getMessageTypeWithInferiors());

		return o;
	}
}
